﻿<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="MailListDetail.ascx.cs"
    Inherits="Zebra.Umbraco.Marcos.MailList.MailListDetail" %>
<form runat="server">
<p class="no-border">
    <asp:Label ID="Label1" runat="server" Text="地址簿名称"></asp:Label><br />
    <asp:Label ID="lbMailListName" runat="server"></asp:Label>
</p>
<p>
    <asp:Label ID="Label2" runat="server" Text="修改时间："></asp:Label><asp:Label ID="lbLastModifiedOn"
        runat="server" Text="Label"></asp:Label>
    <asp:Label ID="Label3" runat="server" Text="联系人地址数量："></asp:Label><asp:Label ID="lbMailCount"
        runat="server" Text="Label"></asp:Label>
</p>
<p class="no-border">
    <asp:GridView ID="GridView1" CssClass="ContactTable" AllowPaging="True" runat="server"
        AutoGenerateColumns="False">
        <Columns>
            <asp:TemplateField>
                <ItemTemplate>
                    <input type="checkbox" name="MailAddressID" value='<%# Eval("MailAddressID") %>' />
                </ItemTemplate>
            </asp:TemplateField>
            <asp:BoundField HeaderStyle-Width="250" HeaderText="邮件地址" DataField="Address" />
            <asp:TemplateField HeaderText="姓名" HeaderStyle-Width="150">
                <ItemTemplate>
                    <asp:Label runat="server" Text='<%# Eval("FirstName") + ", " + Eval("LastName") %>'></asp:Label>
                </ItemTemplate>
            </asp:TemplateField>
        </Columns>
    </asp:GridView>
    <asp:Label ID="lbNoRecord" runat="server" Text="尚未导入联系人" Visible="false"></asp:Label>
</p>
<p class="no-border">
    <input id="Button1" type="button" value="导入联系人" class="button" onclick="location.href='AddContact.aspx'" />
    <asp:Button ID="Button2" CssClass="button" runat="server" OnClientClick="if($('input[name=MailAddressID]:checked').val()){return confirm('请确定是否要删除已选择的联系人')}else{return false;}"
        Text="删除联系人" OnClick="Button2_Click" />
</p>
</form>
